package recipie.core;

import java.util.HashMap;

public class RecipeCollection 
{
	private HashMap<String,Recipe> recipes;
	
	public RecipeCollection(){
		recipes = new HashMap<String,Recipe>() ;
	}
	
	public void addRecipe(Recipe r){
		if(!recipes.containsKey(r.getName())) 
			recipes.put(r.getName(), r);
	}
	
	public boolean containsIngredient(Recipe r){
		if(recipes.containsKey(r.getName())) return true;
		return false;
	}
	
	public HashMap<String,Recipe> getRecipes(){
		return recipes;
	}
}
